package com.meet.service;

import com.meet.entity.ConnectionByWM;
import com.meet.entity.PageBean;
import com.meet.vo.ConnectionVo;

import java.sql.SQLException;
import java.util.List;

/**
 * @author King_of_hehe
 */
public interface ConnectionService {

    /** 删除连接
     *
     * @param id
     * @return
     * @throws SQLException
     */
    public int dropConnection(Integer id) throws SQLException;

    /** 获取所有数据的总数
     *
     * @return
     * @throws SQLException
     */
    public int totalPage() throws SQLException;

    /** 添加数据
     *
     * @param connectionByWM
     * @return
     */
    public int addConnection(ConnectionByWM connectionByWM) throws SQLException;

    /** 根据id获取连接
     *
     * @param id
     * @return
     * @throws SQLException
     */
    public ConnectionByWM getWM(Integer id) throws SQLException;

    /** 查找所有连接
     *
     * @param page
     * @param num
     * @return
     * @throws SQLException
     */
    public PageBean<ConnectionVo> getAllWM(int page, int num,int id) throws SQLException;

    /** 更新连接
     *
     * @param wm
     * @return
     * @throws SQLException
     */
    public int updateWM(ConnectionByWM wm) throws SQLException;

    /** 修改是否确定
     *
     * @param id
     * @return
     * @throws SQLException
     */
    public int yes(Integer id) throws SQLException;
}
